<?php
class Upload extends AppModel {
	var $name = 'Upload';
	var $primaryKey = 'id_uploads';
	
	function afterFind($results){
		foreach($results as &$item){
			if(isset($item['Upload'])){
				$aux = explode('-', $item['Upload']['data']);
				$item['Upload']['data_view'] = $aux[2].'/'.$aux[1].'/'.$aux[0];
			}
		}
		
		return $results;
	}
}
?>